const Service = require('../../../core/service/ApiService');

class UserDao extends Service{

    //家长端
    async findInfoByNumber(number) {
        return this.model.InfoParent.findOne({
            where:{
                child_number:number
            },
            arguments:['child_number','parent_phone']
        })
    }


    //学生端
    async findStudentInfoByNumber(uNumber) {
        return this.model.InfoStudent.findOne({
            where:{
                user_number: uNumber
            },
            arguments:['user_number','password']
        })
    }
}

module.exports = UserDao;
